﻿Imports DTO
Imports DAO

Public Class LopBUS

    Public Function LayBang() As DataTable
        Dim dt As New DataTable
        Dim lopDAO As New LopDAO
        dt = lopDAO.LayBang
        Return dt
    End Function

    Public Function LayDanhSach() As List(Of LopDTO)
        Dim ds As New List(Of LopDTO)
        Dim lopDAO As New LopDAO
        ds = lopDAO.LayDanhSach()
        Return ds
    End Function
    Public Function LayLop(ByVal MaLop) As LopDTO
        Dim tempDAO As New LopDAO
        Return tempDAO.LayLop(MaLop)
    End Function

    Public Function ThemLop(ByVal lopDTO As LopDTO) As Integer
        Dim lopDAO As New LopDAO()
        Return lopDAO.ThemLop(lopDTO)
    End Function


    Public Function XoaLop(ByVal lopDTO As LopDTO) As Integer
        Dim lopDAO As New LopDAO()
        Return lopDAO.XoaLop(lopDTO)
    End Function


    Public Function CapNhatLop(ByVal lopDTO As LopDTO) As Integer
        Dim lopDAO As New LopDAO()
        Return lopDAO.CapNhatLop(lopDTO)
    End Function

End Class
